package com.shujia.common

import org.apache.spark.internal.Logging
import org.apache.spark.sql.SparkSession

abstract class SparkMain extends Logging {
  var day: String = _

  def main(args: Array[String]): Unit = {
    if (args.length == 0) {
      log.error("请指定时间参数")
      return
    }
    day = args.head

    val spark: SparkSession = SparkTool.getSparkSession("UserActionBaseIptv")

    this.run(spark)
  }

  def run(spark: SparkSession): Unit
}
